<?php

/**
 * 公共操作
 * @author wyb
 */

namespace Logistics\Controller;
use Think\Controller;
class BaseController extends Controller {
	
	protected $_get = array();
	protected $_post = array();
	protected $_limit = 10;
	protected $_member_info = array();
	
	public function _initialize() {
		
		$this->_get = $_GET;
		
		$this->_post = $_POST;
		
		foreach( $this->_get as $k => $v ) {
			$this->_get[$k] = htmlspecialchars(trim( $v));
		}
		
		foreach( $this->_post as $k => $v ) {
			$this->_post[$k] = htmlspecialchars(trim( $v));
		} 
        
		$this->_member_info = session('login_info');
		
		if (empty($this->_member_info)){
            $this->error("你未登录，请先登录" , U("public/login"));
        }
		
		$this->assign("conf" , C());
		
		$this->assign("member_info" , $this->_member_info);
	}

}
